<!DOCTYPE html>
<html>
<head>
	<title>推送请求记录</title>
	{{>/WEB-INF/pages/common/meta_base.part.html}}
	{{>/WEB-INF/pages/common/refs_base.part.html}}
	<link href="{{ctx}}/static/bootstrap-datepicker/datepicker.css" type="text/css" rel="stylesheet" />
	<script type="text/javascript" src="{{ctx}}/static/bootstrap-datepicker/bootstrap-datepicker.js"></script>
	<script type="text/javascript" src="{{ctx}}/static/bootstrap-datepicker/locales/bootstrap-datepicker.zh-CN.js"></script>
	<script>
	$(document).ready(function() {
		$('.datepicker').datepicker();
	});
	</script>
</head>
<body>
{{>/WEB-INF/pages/common/layout_header.part.html}}
<div class="container">
	<ul class="breadcrumb">
	  <li><a href="{{ctx}}">首页</a></li>
	  <li><a href="{{ctx}}/system/cloud">云服务</a></li>
	  <li class="active">推送请求</li>
	</ul>
	<hr class="hr1">
	<div class="hr-10"></div>
	<div class="hr-10"></div>
	<div class="hr-10"></div>
	<ul class="nav nav-tabs">
		<li><a href="{{ctx}}/push/create?appId={{appId}}">推送消息</a></li>
		<li class="active"><a href="javascript:void(0);">推送历史</a></li>
		<li><a href="{{ctx}}/push/config?appId={{appId}}">配置管理</a></li>
	</ul>
	<div style="margin:10px 20px 10px">
<form id="search-form" class="form-inline" role="form" action="{{queryPath}}" method="get">
	<div class="form-group">
		<label class="sr-only" for="dtp_submittime">提交日期</label>
		<input id="dtp_submittime" type="text" name="q_EQ_submitTime" readonly class="form-control datepicker" value="{{submitTime}}"
			data-date-format="yyyy-mm-dd" placeholder="提交日期" title="提交日期"/>
	</div>
	<div class="form-group">
		<label class="sr-only" >发送方式</label>
		<select class="form-control" name="q_EQ_receiverType" title="发送方式">
			{{#sendTypes}}
			<option value="{{key}}" {{#selected}}selected{{/selected}}>{{value}}</option>
			{{/sendTypes}}
		</select>
	</div>
	<button id="so_go" class="btn btn-default" type="submit"><span class="glyphicon glyphicon-search"></span>查找</button>
	<div class="form-group">
		<label class="sr-only">排序</label>
		<div class="btn-group">
		{{#sortInfo}}
			<button type="button" class="btn btn-info btn-default dropdown-toggle" data-toggle="dropdown">
			    排序：{{currentSortEntry.text}}
			    {{^noneSortEntry}}
				    {{#currentSortEntry.asc}}↑{{/currentSortEntry.asc}}
				    {{^currentSortEntry.asc}}↓{{/currentSortEntry.asc}}
			    {{/noneSortEntry}}
		    	<span class="caret"></span>
			</button>
		  <ul class="dropdown-menu" role="menu">
		  	{{#sortEntrys}}
		    <li>
		    	<a href="?st_{{name}}={{nextDir}}{{#filterExp}}&{{filterExp}}{{/filterExp}}">
		    	{{text}} 
		    	{{#selected}}
			    	{{#nextAsc}}↑{{/nextAsc}}
			    	{{^nextAsc}}↓{{/nextAsc}}
		    	{{/selected}}
		    	</a>
		    </li>
		    {{/sortEntrys}}
		  </ul>
		{{/sortInfo}}
		</div>
	</div>
	{{#otherParams}}
	<input type="hidden" name="{{key}}" value="{{value}}"/>
	{{/otherParams}}
</form>
    </div>
	<table id="contentTable" class="table table-striped table-bordered table-hover">
		<thead><tr>
		<th width="160px">提交时间</th><th width="200px">发送范围</th><th  class="contentCls">消息内容</th><th width="90px">目标设备数</th>
		</tr></thead>
		<tbody>
		{{#pushRequests.content}}
			<tr>
				<td>
				<script type="text/javascript">
					document.write($.format.date(
							"{{submitTime}}",
							"yyyy-MM-dd HH:mm:ss"))
				</script>
				</td>
				<td>按{{receiverType.description}}:<br/>
				{{^byTags}}
					{{receiverValue}}
				{{/byTags}}
				{{#byTags}}
					{{#tagEntrys}}
						<span class="label label-info">{{key}}={{value}}</span>
					{{/tagEntrys}}
				{{/byTags}}
				</td>
				<td  class="contentCls400">
				{{#message}}
					{{>/WEB-INF/pages/push/message.part.html}}
				{{/message}}
				</td>
				<td><a href="{{ctx}}/push/list-pushs/{{id}}?appKey={{appId}}" title="查看明细">{{affectedDevices}}</a></td>
			</tr>
		{{/pushRequests.content}}
		</tbody>
	</table>
	{{#page}}
	{{>/WEB-INF/pages/common/pagination.part.html}}
	{{/page}}
	{{>/WEB-INF/pages/common/layout_footer.part.html}}
</div>	
</body>
</html>
